package com.cg.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;
import java.time.LocalDateTime;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;

/**
 * <p>
 * 
 * </p>
 *
 * @author lhy
 * @since 2024-12-26
 */
@Getter
@Setter
@Schema(description = "Farm对象")
public class Farm implements Serializable {

    private static final long serialVersionUID = 1L;

    @Schema(description = "牧场唯一标识符，自增主键")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;
    @Schema(description = "牧场名称，字符串类型，非空")
    private String farmName;
    @Schema(description = "场地规模，整数类型，表示牧场占地面积，单位平方米，非空")
    private Integer siteScale;
    @Schema(description = "养殖规模，整数类型，表示当前养殖牲畜的数量，非空")
    private Integer breedingScale;
    @Schema(description = "省，字符串类型，表示牧场所在的省份")
    private String province;
    @Schema(description = "市，字符串类型，表示牧场所在的城市")
    private String city;
    @Schema(description = "区/县，字符串类型，表示牧场所在的区或县")
    private String districtCounty;
    @Schema(description = "详细地址，文本类型，提供牧场的具体位置信息")
    private String address;
    @Schema(description = "位置，POINT类型，存储牧场的经纬度坐标，由地图服务自动生成，非空")
    private String location;
    @Schema(description = "牲畜品种ID，逻辑外键，指向数据字典中牲畜品种对应的记录ID")
    private Integer dictionaryDataId;
    @Schema(description = "状态，布尔值（0或1），1代表启用，0代表停用，默认为启用状态")
    private Boolean status;
    @Schema(description = "创建时间，自动设置为记录创建的时间戳")
    @JsonFormat(shape = JsonFormat.Shape.STRING,pattern = "YYYY-MM-dd")
    private LocalDateTime createdAt;
    @Schema(description = "更新时间，当记录被修改时自动更新为此时间戳")
    @JsonFormat(shape = JsonFormat.Shape.STRING,pattern = "YYYY-MM-dd")
    private LocalDateTime updatedAt;
    @Schema(description = "牲畜品种")
    private String breed;
}
